This application relates to and incorporates herein by reference Japanese Patent Application No. 11-63252 filed on Mar. 10, 1999.
The present invention relates to an automobile control unit provided with a microcomputer, and more particularly relates to an automobile control unit provided with a microcomputer that communicates data with other microcomputers in other automobile control units to thereby share the control data with communicated microcomputers.
An automobile control unit for controlling a control target such as an engine or transmission mounted on an automobile is provided with a microcomputer for performing arithmetic operations for controlling control targets by executing control programs stored in a ROM.
Recently, the control algorithm has become complex, and in such an automobile control unit, a microcomputer mounted on an automobile control unit communicates the data with other microcomputers of other automobile control units to thereby share the control data used for controlling control targets with communicated microcomputers. Thus, the controllability is improved.
Various communication system structures of an automobile control unit (ECU) are known. One exemplary system uses an in-ECU communication system structure for communicating the data one-to-one between two microcomputers mounted on one ECU. Another exemplary system uses an inter-ECU serial communication system structure for communicating the data one-to-one between respective microcomputers mounted on ECUs through a serial communication line provided in an automobile. A still another exemplary system uses an inter-ECU multiple communication system structure for communicating the data one-to-many or many-to-one among microcomputers mounted on respective microcomputers mounted on three or more ECUs through a multiple communication line provided in an automobile.
Furthermore, a system structure having the above systems is also known. For example, the system structure in which a microcomputer mounted on one ECU communicates the data with another microcomputer mounted on the same ECU and also communicates the data with a microcomputer mounted on another ECU through a serial communication line or a multiple communication line has been known.
As described above, various system structures that are different in the communication type are employed for the automobile control unit of this type. Furthermore, various communication protocols are employed even though the communication type of the system structure is the same, and particularly many communication protocols are used for multiple communication. Even though the communication type system structure and the communication protocol are the same, the system structure difference in the allotment of a control part depending on the sender microcomputer and receiver microcomputer and the type of controlling data, and the control data difference in the type of control data to be communicated, data length, and arrangement of control data of the communication data string actually communicated are factor in the additional variation.
However, in the above automobile control unit, a program to be executed by a microcomputer includes a part for the arithmetic operation for controlling the target to be controlled and a part for performing communication operation of the control data to be communicated between communication targets, and these parts are not defined clearly and are formed inseparably.
Therefore, in such automobile control units, the whole program must be widely modified in the wide range every time when the communication type or control part allotment of the system structure or communication protocol is changed. Furthermore, it is difficult to reuse a program that has been developed for the purpose of a certain unit having a certain system structure for another unit having another system structure.
For example, in the above automobile control unit, a control program that is provided for control arithmetic operation depending on the control target is used not only for calculation of the control data but also for conversion of the calculated control data to the communication data string corresponding to the communication protocol between communication targets. The communication data string is transmitted with transmission timing determined according to the communication protocol or baud rate. On the other hand, the communication data string transmitted from a communication target by means of the control program is received at the timing determined according to the communication protocol or baud rate, the control data included in the communication data string is written in a memory area that will be referred to when arithmetic operation is performed. Therefore, if the communication protocol to the communication target or the data type or data length of the control data to be communicated is changed, the whole program must be modified.
It is the object of the present invention to provide an automobile control unit that minimizes the modification of a program to be executed by a microcomputer when the system structure or communication protocol is changed.
According to the present invention, independent program modules include a data conversion program and a communication driver program, which are provided separately from the application program for performing the control arithmetic operation corresponding to a control target. The modules convert the control data to be transmitted to a communication target to a communication data string corresponding to a communication protocol, and transmit the communication data string to the communication target according to the communication protocol. Therefore, it is not necessary to modify the application program even though the communication protocol is changed, or the data type or data length of the control data to be transmitted to the communication target or the arrangement of the control data in the communication data string is changed.
Only the data conversion program need be modified and it is not necessary to modify the communication driver program and application program as long as the communication protocol is the same even though the type or data length of the control data to be transmitted to the communication target or the arrangement of the control data in the communication data string is changed concomitantly with the system structure change.